.button {
  display: flex;
  height: 2.5rem;
  touch-action: none;
  user-select: none;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  white-space: nowrap;
  border-style: none;
  background-color: hsl(204 20% 100%);
  padding-left: 1rem;
  padding-right: 1rem;
  font-size: 1rem;
  line-height: 1.5rem;
  color: hsl(204 10% 10%);
  text-decoration-line: none;
  outline-width: 2px;
  outline-offset: 2px;
  outline-color: hsl(204 100% 40%);
  box-shadow:
    inset 0 0 0 1px rgba(0, 0, 0, 0.1),
    inset 0 -1px 0 rgba(0, 0, 0, 0.1),
    0 1px 1px rgba(0, 0, 0, 0.1);
  width: 100%;
  border-radius: 0.375rem;
}

.button:hover {
  background-color: hsl(204 20% 96%);
}

.button[aria-disabled='true'] {
  opacity: 0.5;
}

.button[aria-expanded='true'] {
  background-color: hsl(204 20% 96%);
}

.button[data-focus-visible] {
  outline-style: solid;
}

.button:active,
.button[data-active] {
  transform: scale(0.98);
}

.button:active[aria-expanded='true'],
.button[data-active][aria-expanded='true'] {
  transform: scale(1);
}

:is(.dark .button) {
  background-color: hsl(204 20% 100% / 0.05);
  color: hsl(204 20% 100%);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.1),
    inset 0 -1px 0 1px rgba(0, 0, 0, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

:is(.dark .button:hover) {
  background-color: hsl(204 20% 100% / 0.1);
}

:is(.dark .button)[aria-expanded='true'] {
  background-color: hsl(204 20% 100% / 0.1);
}

@media (min-width: 640px) {
  .button {
    gap: 0.5rem;
  }
}

.secondary {
  background-color: transparent;
  color: currentColor;
  box-shadow: none;
}

.secondary:hover {
  background-color: hsl(204 10% 10% / 0.05);
}

:is(.dark .secondary) {
  background-color: transparent;
  box-shadow: none;
}

:is(.dark .secondary:hover) {
  background-color: hsl(204 20% 100% / 0.05);
}

.wrapper {
  display: flex;
  width: 320px;
  max-width: 100%;
  flex-direction: column;
  gap: 1.5rem;
  border-radius: 0.5rem;
  background-color: hsl(204 20% 100%);
  padding: 1rem;
  box-shadow:
    0 1px 3px 0 rgb(0 0 0 / 0.1),
    0 1px 2px -1px rgb(0 0 0 / 0.1);
}

:is(.dark .wrapper) {
  background-color: hsl(204 3% 18%);
  box-shadow:
    0 1px 3px 0 rgb(0 0 0 / 0.25),
    0 1px 2px -1px rgb(0 0 0 / 0.1);
}

.heading {
  margin: 0px;
  margin-top: 0.5rem;
  font-size: 1.25rem;
  line-height: 1.75rem;
  font-weight: 600;
  color: hsl(204 10% 10%);
}

:is(.dark .heading) {
  color: hsl(204 20% 100%);
}

.field {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.input {
  height: 2.5rem;
  width: 100%;
  border-radius: 0.375rem;
  border-style: none;
  background-color: hsl(204 20% 94% / 0.4);
  padding-left: 1rem;
  padding-right: 1rem;
  font-size: 1rem;
  line-height: 1.5rem;
  color: hsl(204 10% 10%);
  box-shadow:
    inset 0 0 0 1px rgba(0 0 0 / 0.1),
    inset 0 2px 5px 0 rgba(0 0 0 / 0.05);
}

.input::placeholder {
  color: hsl(204 10% 10% / 0.6);
}

.input:hover {
  background-color: hsl(204 20% 94%);
}

.input:focus-visible,
.input[data-focus-visible] {
  outline: 2px solid hsl(204 100% 40%);
  outline-offset: 0px;
}

:is(.dark .input) {
  background-color: hsl(204 3% 12%);
  color: hsl(204 20% 100%);
  box-shadow:
    inset 0 0 0 1px rgba(255 255 255 / 0.12),
    inset 0 -1px 0 0 rgba(255 255 255 / 0.05),
    inset 0 2px 5px 0 rgba(0 0 0 / 0.15);
}

:is(.dark .input)::placeholder {
  color: hsl(204 20% 100% / 46%);
}

:is(.dark .input:hover) {
  background-color: hsl(204 3% 10%);
}

.error {
  width: fit-content;
  border-radius: 0.375rem;
  border-width: 1px;
  border-color: hsl(357 56% 80%);
  background-color: hsl(357 56% 80% / 0.4);
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
  padding-left: 1rem;
  padding-right: 1rem;
  color: hsl(357 100% 30%);
}

.error:empty {
  display: none;
}

:is(.dark .error) {
  border-color: hsl(357 56% 50% / 0.4);
  background-color: hsl(357 56% 42% / 0.25);
  color: hsl(357 100% 90%);
}

.buttons {
  display: flex;
  gap: 1rem;
  padding-top: 1rem;
}

.reset {
  border-width: 1px;
  border-style: solid;
  border-color: hsl(204 20% 88%);
  font-weight: 600;
  color: hsl(204 10% 10% / 0.7);
}

:is(.dark .reset) {
  border-color: hsl(204 3% 26%);
  color: hsl(204 20% 100% / 0.7);
}
